package com.zxx.pattern.proxyPattern.aidl;

import android.app.Service;
import android.content.Intent;
import android.os.IBinder;

import com.zxx.pattern.proxyPattern.aidl2.BankBinder2;

import androidx.annotation.Nullable;

/**
 * 代替服务端（当前是在同一进程下，所以能访问，假如把进程改为其他进程，就无法访问了，这时就要用AIDL了）
 *
 * @author zxx on 2021/5/18
 */
public class BankService extends Service {

    @Nullable
    @Override
    public IBinder onBind(Intent intent) {
        //return new BankBinder();
        return new BankBinder2();
    }
}
